<template>
	<div>
		<div>
			<span class='m-l-10'>
				<span>日期</span>
				<el-date-picker
				 @change='search'
					style='width:250px'
					class='m-l-10'
					size='mini'
				  v-model='filter.date'
				  type='daterange'
				  align='right'
				  unlink-panels
				  range-separator='-'
				  value-format="yyyy-MM-dd"
				  start-placeholder='开始日期'
				  end-placeholder='结束日期'>
				</el-date-picker>
			</span>
			<span class='m-l-30'>
				<el-button size='mini' type='primary' :icon='{"el-icon-download" : !downloadLoading, "el-icon-loading" : downloadLoading}' @click='handleDownload'>导出</el-button>
			</span>
		</div>
		<section class='m-t-50'>
			<el-table style='font-size:12px;text-align:center;' ref='multipleTable' :data='logList'>
				<el-table-column label='日期' align='center'>
					<template slot-scope='scope'>{{ scope.row.day | parseTime('{y}-{m}-{d}') }}</template>
				</el-table-column>
				<el-table-column label='微信充电金额' align='center'>
					<template slot-scope='scope'>{{ scope.row.wx_charge }} 元</template>
				</el-table-column>
				<el-table-column label='线上卡充电金额' align='center'>
					<template slot-scope='scope'>{{ scope.row.online_card_charge }} 元</template>
				</el-table-column>
				<el-table-column label='总金额' align='center'>
					<template slot-scope='scope'>{{ scope.row.amount }} 元</template>
				</el-table-column>
				<el-table-column fixed='right' align='center'>
					<template slot-scope='scope'>
						<router-link class='color-primary' :to='"/order/chargeDetail/" + scope.row.order_id'>明细</router-link>
					</template>
				</el-table-column>
			</el-table>
			
			<div class='m-t-30'>
				<pagination ref='pagination' :query='pageQuery' v-on:page='page' url='Finance/dayIncome'></pagination>
			</div>
			
		</section>
		
	</div>
</template>

<script src='./dayIncome.js'></script>